<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        function unique1(arr) {
            return Array.from(new Set(arr))
        }
        function unique2(arr) {
            return arr.filter((item, index) => {
                return arr.indexOf(item) === index
            })
        }
        function unique3(arr) {
            let newArr = []
            arr.forEach(item => {
                if (!newArr.includes(item)) {
                    newArr.push(item)
                }
            })
            return newArr
        }
        console.log(unique1([1, 1, 2, 3, 4, 4, 5, 6, 6, 7, 8, 8, 9, 9, 10]))
        console.log(unique2([1, 1, 2, 3, 4, 4, 5, 6, 6, 7, 8, 8, 9, 9, 10]))
        console.log(unique3([1, 1, 2, 3, 4, 4, 5, 6, 6, 7, 8, 8, 9, 9, 10]))
    </script>
</body>
</html>